package com.bdqn.Short.aop;

import com.bdqn.Short.Jd1.Equip;
import org.aspectj.lang.JoinPoint;

public class EquipAop {
    public void before(JoinPoint joinPoint){
        Equip arg =(Equip) joinPoint.getArgs()[0];
        if (arg.getType().equals("指环")){
            String name=arg.getName();
            arg.setName("紫色梦幻"+arg.getName());
            System.out.println(name+"升级为"+arg.getName());
            arg.setAttackPlus(arg.getAttackPlus()+6);
            arg.setDefencePlus(arg.getDefencePlus()+6);
        }

    }
}
